package cn.initcap.bio.point2point.client;

import cn.initcap.bio.udp.search.client.UdpSearcher;
import cn.initcap.bio.udp.search.client.bean.ServerInfo;
import java.io.IOException;

/**
 * @author initcap
 * @date Created in 5/1/19 3:46 PM.
 */
public class Client {

    public static void main(String[] args) {
        ServerInfo info = UdpSearcher.searchServer(10000);
        System.out.println("server:" + info);

        if (info != null) {
            try {
                TcpClient.linkWith(info);
            } catch (IOException e) {
                e.printStackTrace();
            }
        }
    }

}
